{% extends '::base.html.twig' %} 
{% block module_name %}Inventario :: Bodega {{nombreBodega}} :: Articulo {{articulo.marca}} {{articulo.modelo}}{% endblock %}
{% block title %}Inventario :: Bodega{% endblock %}
{% block customScripts %}
<script src="{{ asset('bundles/EndorBundle/js/jquery.dataTables.min.js') }}"></script>
{% endblock %}
{% block body2 %}

<div class="row">
        <div class="col_7">
        <div class="widget clear_fix">
            <h2>Entradas</h2>
            <div class="widget_inside">

                <table class="regular">
                    <thead>
                        <tr>
                            <th>Fecha de Entrada</th>
                            <th>Cantidad</th>
                            <th style="width: 100px;">Acciones</th>
                        </tr>
                    </thead>
                    <tbody>
                        {% for entrada in entradas %}
                            <tr>
                                <td>
                                    {{entrada.fechaEntrada.format("d/m/Y - H : i : s")}}
                                </td>
                                <td>
                                    {{entrada.cantidad}}
                                </td>
                                <td>
                                    <a href="{{ urlNuevaSalidaCondicionada }}/{{entrada.id}}" class="button small blue">Agregar Salida</a>
                                </td>
                            </tr>
                        {% endfor %}
                    </tbody>
                </table>
            </div>
        </div>
    </div>

    <div class="col_5 last">
        <div class="widget clear_fix">
            <h2>Salidas</h2>
            <div class="widget_inside">
                <table class="regular">
                    <thead>
                        <tr>
                            <th>Fecha de Salida</th>
                            <th>Cantidad</th>
                        </tr>
                    </thead>
                    <tbody>
                        {% for salida in salidas %}
                            <tr>
                                <td>
                                    {{salida.fecha.format("d/m/Y - H : i : s")}}
                                </td>
                                <td>
                                    {{salida.cantidad}}
                                </td>
                            </tr>
                        {% endfor %}
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>
<script>
$(document).ready(function(){
    $('.regular').dataTable({
        "sPaginationType": "full_numbers",
        "bJQueryUI": true
    });
});
</script>
{% endblock %}